/**
* Copyright (C) qzgf, 2012
*
* License        :Apache License 2.0
* Project        :qzgfjava
* Package        :com.qzgf.application.appsystem.main.action
* File	         :main.java
* Written by     :fjfdszj
* Created Date   :May 21, 2012
* Purpose        :功能描述

======================================

* Modifyer by    :fjfdszj
* Update Date    :May 21, 2012
* Purpose        :描述

*/
package com.qzgf.application.appsystem.department.action;

import java.util.List;

import com.qzgf.application.BaseAction;
import com.qzgf.application.appsystem.main.domain.MainFacade;

/**
 * Purpose      : 说明
 *
 * @author fjfdszj
 * @see     DepartmentAction.java
 *
 */
public class DepartmentAction extends BaseAction{
	/**
	 * Purpose      : 说明
	 */
	
	private MainFacade mainFacade;
	
	
	
	
	
	/**
	 * 
	 * Purpose      : 框架左菜单
	 * @return
	 */
	public String GetTreeJson() {
		List menuList = mainFacade.findMenu("0");
		StringBuffer menustr = new StringBuffer();
		menustr.append("[");
		menustr.append(mainFacade.GetTree(menuList,"0"));
		menustr.append("]");
		json = menustr.toString();
		return viewjson;
	}

	
	/**
	 * 
	 * Purpose      : 用户信息验证
	 * @return
	 */
	public String Login(){
		java.lang.StringBuffer sb = new StringBuffer();
		sb.append(true);
		json = sb.toString();
		return viewjson;
	}
	
	/**
	 * 
	 * Purpose      : 框架页面
	 * @return
	 */
	public String index(){
		return SUCCESS;
	}
	//=======================================================常量设置=================================
	//=================================================================================================
	/**
	 * Purpose      : 说明
	 * @return the mainFacade
	 */
	public MainFacade getMainFacade() {
		return mainFacade;
	}

	/**
	 * Purpose      : 说明
	 * @param mainFacade the mainFacade to set
	 */
	
	public void setMainFacade(MainFacade mainFacade) {
		this.mainFacade = mainFacade;
	}

}
